package it.sd.pwframework.business.service.crud.impl;

import it.sd.pwframework.business.service.crud.RemoteSourceService;
import it.sd.pwframework.persistence.common.CommonSession;
import it.sd.pwframework.persistence.model.RemoteSource;

import java.util.HashMap;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Propagation;
import org.springframework.transaction.annotation.Transactional;


@Service("remoteSourceService")
public class RemoteSourceServiceImpl extends AbstractCrudService<RemoteSource> implements RemoteSourceService {

    @Autowired
    private CommonSession commonSession;

	@Override
	@Transactional(propagation=Propagation.REQUIRED)
	public RemoteSource getByCode(String codice) throws Exception {
		
    	HashMap<String, Object> props = new HashMap<String, Object>();
    	props.put("codice", codice);
    	return getByProperites(props);
    	
	}

	
	
	
}
